package cn.com.guage.dtm.check.execute;

import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.ApplicationArguments;
import org.springframework.boot.ApplicationRunner;
import org.springframework.context.annotation.Configuration;
import cn.com.guage.dtm.check.client.JobTaskClient;

@Configuration
public class DemoApplicationRunner implements ApplicationRunner {
	
    protected final Logger logger = LoggerFactory.getLogger(this.getClass());

	@Autowired
	private JobTaskClient jobTaskClient;

	@Override
	public void run(ApplicationArguments args) throws Exception {
		logger.info("-------------------------------任务开始执行!");
		jobTaskClient.execute();
		logger.info("-------------------------------任务执行结束!");
	}
}